package cn.wolfcode.shop.cloud.redis;

public class SecKillKeyPrefix implements KeyPrefix {

    private int expireTime;
    private String keyPrefix;



    public SecKillKeyPrefix(int expireTime, String keyPrefix) {
        this.expireTime = expireTime;
        this.keyPrefix = keyPrefix;
    }
    public static final SecKillKeyPrefix SECKILL_STOCK_COUNT=new SecKillKeyPrefix(0,"seckill_stock_count:");
    public static final SecKillKeyPrefix SECKILL_CREATE_ORDER=new SecKillKeyPrefix(0,"seckill_create_order:");
    public static final SecKillKeyPrefix SECKILL_GOOD_HASH=new SecKillKeyPrefix(0,"seckill_good_hash");
    public static final SecKillKeyPrefix SECKILL_PATH=new SecKillKeyPrefix(5,"seckill_path:");
    public static final SecKillKeyPrefix SECKILL_VERIFY_CODE=new SecKillKeyPrefix(60,"seckill_verify_code:");




    @Override
    public String getPreix() {
        return this.keyPrefix;
    }

    @Override
    public int getExpireTime() {
        return this.expireTime;    }
}


